const getters = {
  avatar: state => state.user.avatar,
  sidebar: state => state.app.sidebar,
  device: state => state.app.device,
  token: state => state.user.token, // 把token存储到 vuex中的全局计算属性中，方便后期调用
  name: state => state.user.userInfo.username, // 建立用户名称的映射
  staffPhoto: state => state.user.userInfo.staffPhoto, // 建立用户头像的映射
  routes: state => state.permisson.routes, // 导出当前的路由
  roles: state => state.user.userInfo.roles, // 用户权限按钮
  departmentName: state => state.user.userInfo.departmentName, // 员工部门
  companyName: state => state.user.userInfo.companyName// 员工公司
}
export default getters
